//
//  SEGPublishHouseListViewModel.h
//  Commom
//
//  Created by 梁学彰 on 2020/6/4.
//

#import <Foundation/Foundation.h>
#import "ReactiveObjC.h"

typedef NS_ENUM(NSUInteger, SEGEnumPublishHouseType) {
    SEGEnumPublishHouseTypeZL = 0, /*租赁*/
    SEGEnumPublishHouseTypeCS = 1 /*出售*/
};

typedef NS_ENUM(NSUInteger, SEGEnumReantType) {
    SEGEnumReantType_Publish = 0, /*发布*/
    SEGEnumReantType_Edit = 1 /*编辑*/
};

NS_ASSUME_NONNULL_BEGIN

@interface SEGPublishHouseListViewModel : NSObject
@property (nonatomic, strong) NSArray<NSArray*> *dataSoure;

@property (nonatomic, strong)NSMutableDictionary *requestParams;

@property (nonatomic, strong)NSArray<NSString*> *imageData;
@property (nonatomic, strong)NSIndexPath *imageDataIndexPath;
@property (nonatomic, strong)NSDictionary *selectedData;
@property (nonatomic, strong)NSArray<NSDictionary*> *selectedTags;

/**
 发布类型
 */
@property (nonatomic, assign) SEGEnumPublishHouseType type;
/**
 判断是发布还是编辑
 */
@property (nonatomic, assign) SEGEnumReantType reantType;

/**
 租售类型 1:整租 2:独立房间 3:合租床位 4:出售
 */
@property (nonatomic, copy) NSString *rentalType;

/**
 房屋租售主键ID
 */
@property (nonatomic, copy) NSString *rentalId;


- (void)destroyResource;

- (RACSignal *)loadDataWithSignal;

- (RACSignal *)sendSaveRequest;

- (RACSignal *)sendSaveImageRequestWithPhotos:(NSArray<UIImage *> *)photos;


@end

NS_ASSUME_NONNULL_END
